package com.neusoft.my12306.controller;


import com.neusoft.my12306.common.res.CommonResult;
import com.neusoft.my12306.entity.Passenger;
import com.neusoft.my12306.service.IPassengerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author 段静迪
 * @since 2023-07-03
 */
@RestController
@RequestMapping("/p")
@CrossOrigin
public class PassengerController {
    @Autowired
    IPassengerService  passengerService;

    @GetMapping("/q/findall")
    public CommonResult findAll(){
        return   passengerService.findAll();
    }
}
